package com.jirong.shop.vo;

import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.ToString;

@Getter
//@NoArgsConstructor
@AllArgsConstructor
@ToString
public enum RespBeanEnum {
    //通用返回状态，用枚举定义
    SUCCESS(200, "SUCCESS"),
    ERROR(500, "服务端异常"),
    //登录模块5002xx
    LOGIN_ERROR(500210, "用户名或密码不正确"),
    MOBILE_ERROR(500211, "手机号码格式不正确"),
    BIND_ERROR(500121, "参数异常"),
    MOBILE_NOT_EXIST(500213, "手机号码不存在"),
    PASSWORD_UPDATE_FAIL(500214, "密码更新失败"),
    //    秒杀模块
    EMPTY_STOCK(500201, "库存不足"),
    REPEATE_ERROR(500501, "该商品每人限购一件"),
    SESSION_ERROR(500520, "没有该用户,请登录"),
    ORDER_NOT_EXIST(50222, "没有该商品"),
    REQUEST_ILLEGAL(33333, "非法请求，重新抢购"),
    ERROR_CAPTCHA(33334, "验证码有误,请重新输入"),
    ACCESS_LIMIT_REACHED(33335, "访问过与频繁");
    private final Integer code;
    private final String message;
}
